package com.example.demo.Dto;

import com.fasterxml.jackson.annotation.JsonFormat;
import jakarta.validation.constraints.Min;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.stereotype.Component;

@Data
@AllArgsConstructor
@NoArgsConstructor
@Component
public class SearchProductsDto {
    @Min(1)
    private Integer page = 1;


    @Min(1)
    private Integer pageSize = 20;


    private String productName;


    @JsonFormat(shape = JsonFormat.Shape.NUMBER_FLOAT)
    private Float priceLow;


    @JsonFormat(shape = JsonFormat.Shape.NUMBER_FLOAT)
    private Float priceHigh;


    private Integer sold;

    private Integer stock;

    private String merchantName;

    private String categoryName;
}
